#include <stdio.h>
#include <math.h>
int main(void)
{
	int numbers[]={7,10,13,16,19};
	int q=sizeof(numbers)/sizeof(int);
	for(int i=0;i<q;i++){
		int flag=0;
		if(numbers[i]==1){
			flag=1;
		}else{
			for(int x=2;x<=sqrt(numbers[i]);x++){
				if(numbers[i]%x==0){
					flag=1;
					break;
				}
			}
		}
		if(flag){
			printf("%d不是素数\n",numbers[i]);
		}else{
			printf("%d是素数\n",numbers[i]);
		}
	}
	//在编译的时候，要记得链接math.h,即：gcc hmwk6.c -o hmwk6 -lm
	return 0;
}
